home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / std / c++ / 598 < prev    next >
Encoding:
Internet Message Format  |  1996-08-06  |  1.6 KB

  1. Path: chronicle.mti.sgi.com!austern
  2. From: clamage@Eng.Sun.COM (Steve Clamage)
  3. Newsgroups: comp.std.c++
  4. Subject: Re: double& rd2 = 2.0;  // error?
  5. Date: 29 Feb 1996 14:06:44 PST
  6. Organization: Sun Microsystems Inc.
  7. Approved: austern@isolde.mti.sgi.com
  8. Message-ID: <4h4uvs$3m6@engnews1.Eng.Sun.COM>
  9. References: <3135D175.87E@cteq07.pa.msu.edu>
  10. Reply-To: clamage@Eng.Sun.COM
  11. NNTP-Posting-Host: isolde.mti.sgi.com
  12. X-Original-Date: 29 Feb 1996 19:32:12 GMT
  13. X-Auth: PGPMoose V1.1 PGP comp.std.c++
  14.     iQBVAwUBMTYjhky4NqrwXLNJAQHeoQH/Rqq6ww0vUO3seozBdQD0u/UJLqql3Qjq
  15.     itIaWAFEqocjQgfLqh9PDJFH0m9vqHrf2o4woqYLnNOLc8Loj8vwPA==
  16.     =ZB59
  17. Originator: austern@isolde.mti.sgi.com
  18.  
  19. In article 87E@cteq07.pa.msu.edu, David Bowser-Chao <davechao@cteq07.pa.msu.edu> writes:
  20. >Looking at the April 1995 working draft proposal,
  21. >the fragment:
  22.  
  23. >   double& rd2 = 2.0; 
  24.  
  25. >is deemed illegal (non-const references are not initialized from 
  26. >temporaries) but the GNU g++ 2.7.2 as well as the DEC VMS compiler 
  27. >(current release, don't remember, as well as the version I'm 
  28. >field-testing) allow this statement with a mere warning.
  29.  
  30. The current draft says the same thing, with the same example.
  31.  
  32. Some compilers allow such reference binding for compatibility with
  33. old compilers which incorrectly allowed it.
  34.  
  35. ---
  36. Steve Clamage, stephen.clamage@eng.sun.com
  37. ---
  38. [ comp.std.c++ is moderated.  To submit articles: Try just posting with your 
  39.                 newsreader.  If that fails, use mailto:std-c++@ncar.ucar.edu
  40.   comp.std.c++ FAQ: http://reality.sgi.com/austern/std-c++/faq.html
  41.   Moderation policy: http://reality.sgi.com/austern/std-c++/policy.html
  42.   Comments? mailto:std-c++-request@ncar.ucar.edu 
  43. ]
  44.